const service = require("../services/type");

class Controller {
	async list(req, res) {
		res.json(await service.list());
	}
	async add(req, res) {
		res.json(await service.add(req.body));
	}
	async update(req, res) {
		res.json(await service.update(req.body));
	}
	async del(req, res) {
		res.json(await service.del(req.body));
	}
}

module.exports = new Controller();
